/**
 * Created by zzy on 2017/9/6.
 */
import RequestUtil from '../util/NetUtil'

export default class NetRequest{

    //获取水票详情
   static getTiketInfo(param){
       return RequestUtil.requestData('shop/productItem',param);
    }

    //获取地址列表
    static getAddressList(){
        return RequestUtil.requestData('delivery/addressList',{});
    }

    //创建收货地址
    static createAddress(param){
        return RequestUtil.requestData('delivery/create',param);
    }

    //加减购物车
    static shoppingCartAction(param,actionType){
        return RequestUtil.requestData('shop/shoppingcart/'+actionType,param);
    }

    //确认订单购物车信息
    static confirmOrderInfo(param,actionType){
        return RequestUtil.requestData('order/confirmOrderInfo/'+actionType,param);
    }

    //生成订单
    static createOrder(param){
        return RequestUtil.requestData('order/create',param);
    }

    //确认支付
    static confirmOrderPay(param){
        return RequestUtil.requestData('client/pay/confirm',param);
    }

    //确认订单水票操作
    static confirmOrderTiketAcyion(param,actionType){
        return RequestUtil.requestData('ticket/'+actionType,param);
    }

    //支付查询 /client/pay/queryResult
    static payQueryResult(param){
        return RequestUtil.requestData('client/pay/queryResult',param);
    }

    //删除地址
    static deleveryDelete(param){
        return RequestUtil.requestData('delivery/delete',param);
    }
    //水票列表
    static userWaterTicketModelList(param){
        return RequestUtil.requestData('user/watertickets',param);
    }
    //设置默认地址
    static defaultAddress(param){
        return RequestUtil.requestData('delivery/defaultAddress',param);
    }
}

